package com.basic.business.store.domain;

import com.basic.common.annotation.EnumFiledConvert;
import com.basic.common.core.domain.BaseEntity;
import com.basic.common.utils.easyExcel.ExcelEnumConvert;
import lombok.Getter;
import lombok.Setter;
import cn.idev.excel.annotation.ExcelProperty;
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
import com.basic.common.utils.StringUtils;
import com.basic.common.utils.uuid.ULID;

/**
 * 店铺管理对象 t_store_mgmt
 *
 * @author zhaoxy_jn@163.com
 * @date 2025-02-11
 */
@Getter
@Setter
@ExcelIgnoreUnannotated
public class TStoreMgmt extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** $column.columnComment */
    private String id;

    @ExcelProperty(value ="商户号")
    private String merchantCode;

    @ExcelProperty(value ="账单号")
    private String billNo;

    /** 快麦平台店铺编码 */
    @ExcelProperty(value = "快麦平台店铺编码")
    private String kmStoreCode;

    /** 财务店铺编码 */
    @ExcelProperty(value = "财务店铺编码")
    private String finStoreCode;

    /** 财务店铺名称 */
    @ExcelProperty(value = "财务店铺名称")
    private String finStoreName;

    /** 店铺名称 */
    @ExcelProperty(value = "店铺名称")
    private String storeName;

    /** 店铺简称 */
    @ExcelProperty(value = "店铺简称")
    private String storeAbbr;

    /** 事业部名称 */
    @ExcelProperty(value = "事业部名称")
    private String divName;

    /** 店铺类型 */
    @ExcelProperty(value = "店铺类型")
    private String storeType;

    /** 店铺负责人 */
    @ExcelProperty(value = "店铺负责人")
    private long storeLeader;

    /** 所属平台 */
    @ExcelProperty(value = "所属平台")
    private String platName;

    /** 状态 正常：NORMAL 删除：DELETED */
    @ExcelProperty(value = "状态", converter = ExcelEnumConvert.class)
    @EnumFiledConvert(enumMap = "NORMAL=正常,DELETED=删除")
    private String storeStatus;

    public void setId(String id) {
        this.id = StringUtils.isNotEmpty(id) ? id : ULID.getId();
    }
}
